home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Cream of the Crop 1
/
Cream of the Crop 1.iso
/
CAD
/
HPSRT08.ARJ
/
HPSORT.DOC
< prev
next >
Wrap
Text File
|
1991-03-30
|
64KB
|
1,804 lines
HPSORT
Pen Plotter Pen Motion Optimizer
and
File Compressor
for HPGL Compatibile Plotters
CNT Software
1615 Highland Ave.
Janesville, Wis 53545
Copywrite 1991. All Rights Reserved.
Any trademarks metioned in this document are the property of
there respective companies.
1
Table of Contents
1.0 Introduction . . . . . . . . . . . . . . . . . . . . . . 3
1.1 Will HPSORT work with my software? . . . . . . . . . . . 3
2.0 Legal Stuff . . . . . . . . . . . . . . . . . . . . . . . 4
2.1 Warranty . . . . . . . . . . . . . . . . . . . . . . 4
2.2 License . . . . . . . . . . . . . . . . . . . . . . 5
2.3 Ordering Information . . . . . . . . . . . . . . . . 5
3.0 Installation . . . . . . . . . . . . . . . . . . . . . . 6
3.1 System Requirements . . . . . . . . . . . . . . . . 6
3.1 Installation . . . . . . . . . . . . . . . . . . . . 6
4.0 Configuration . . . . . . . . . . . . . . . . . . . . . . 6
4.1 Control Keys . . . . . . . . . . . . . . . . . . . 7
4.2 Opening Configuration Menu . . . . . . . . . . . . . 8
4.2.1 Edit Configuration Data . . . . . . . . . . . 9
4.2.2 General Data Editing . . . . . . . . . . . 10
4.2.3 Swapping Polylines to Disc . . . . . . . . 16
4.2.4 Label commands . . . . . . . . . . . . . . 17
4.2.5 Serial Input / Output Communication Parame-
ters . . . . . . . . . . . . . . . . . . . . 20
4.2.6 Disc Parameters . . . . . . . . . . . . . 21
4.3 Default Settings . . . . . . . . . . . . . . . . . 23
4.4 Sort / Compress . . . . . . . . . . . . . . . . . . . . 24
4.5 Save . . . . . . . . . . . . . . . . . . . . . . . 24
4.6 Quit . . . . . . . . . . . . . . . . . . . . . . . 24
5.0 Operation . . . . . . . . . . . . . . . . . . . . . . . 24
5.1 Theory of Operation . . . . . . . . . . . . . . . 25
5.2 HPSORT & Desqview . . . . . . . . . . . . . . . . 26
6.0 problems . . . . . . . . . . . . . . . . . . . . . . . 26
6.1 Error Messages . . . . . . . . . . . . . . . . . . 26
6.2 Incompatibilities . . . . . . . . . . . . . . . . 27
6.3 How to contact CNT Software . . . . . . . . . . . 27
Order Form . . . . . . . . . . . . . . . . . . . . . . . . 28
2
1.0 Introduction
HPSORT sorts and compresses plot files for Hewlett Packard and
compatible pen plotters using the HPGL (Hewlett Packard Graphics
Language) language. The sorting function initially analyzes the
plot file produced by a CAD package. Then it creates a new file
of the same plot that saves 10% to 30% of the plotting time.
While creating this file, HPSORT writes a "denser" sequence of
instructions reducing the file to about 50% to 60% of it's
original size.
For those persons communicating with a plotting service bureau,
the output files may be automatically compressed using PKZIP, ARC
or other similar program. The resulting output files are typic-
ally be 15% of original file size. Service bureau's will supply
compression program information to use.
How does HPSORT perform this magic on the plot files?
Most CAD packages do not sort plotter files for minimum pen
motion and plot time. They typically create the plot in the
order that the operator created the file. Most CAD packages do
not optimize pen motion because this procedure requires a sig-
nificant amount of processing time and RAM memory in the proces-
sor.
HPSORT works well with software that are capable of producing
HPGL plot files. It will be a judgement call for each user if
the benefits of HPSORT are worth the computing time costs. It
will depend on the size of the plot files, the speed of your
plotter and the speed of your computer.
1.1 Will HPSORT work with my software?
HPSORT does not work equally well with all software that is
capable of generating a plot file. It is optimized to work with
those instructions that are commonly used by CAD and other
Graphics software.
Most of these packages only use a subset of the full instruction
set available. It is this instruction set the HPSORT uses. For
instructions outside of this subset, HPSORT outputs all of the
data it has read in, then copies that instruction to the output.
It then begins the sorting the rest of the input file.
3
HPSORT does not work the following two types of software:
o If the software does a lot of pen changing, HPSORT probably
will not work very well (although try it).
o It does not work with Microsoft Windows 3.x. Microsoft uses
features of the HPGL language that work with the plotters,
but are contrary to the documentation in HP's manuals.
HPSORT does not understand the syntax as of yet.
Future versions will correct these exceptions.
For a list of software the HPSORT works with, run the config-
uration utility HP_CFG. If the list does not contain your
software, try using the generic settings. For well behaved pack-
ages, you should have no problems. Either way, if either it
works or not, please let the author know of your experience. We
will update the list of packages.
If it does not, it is usually a very simple thing to correct
(and I will). Refer to Section 6.3 of this document on how to
contact the author. If HPSORT does not work, we would appreciate
getting a sample of your more complicated drawings to test rather
than just a single drawing.
2.0 Legal Stuff
2.1 Warranty
The CNT Software makes no warranty of any kind, express or
implied,including without limitation, any warranties of merchan-
tability and/or fitness for a particular purpose. CNT Software
shall not be liable for any damages, whether direct, indirect,
special or consequential arising from a failure of this program
to operate in the manner desired by the user. CNT Software shall
not be liable for any damage to data or property which may be
caused directly or indirectly by the use of this program.
IN NO EVENT WILL CNT SOFTWARE BE LIABLE TO YOU FOR ANY
DAMAGES, INCLUDING ANY LOST PROFITS, LOST SAVINGS OR
OTHER INCIDENTAL OR CONSEQUENTIAL DAMAGES A RISING OUT
OF YOUR USE OR INABILITY TO USE THE PROGRAM, OR FOR ANY
CLAIM BY ANY OTHER PARTY.
4
2.2 License
HPSORT is not, and has never been in the Public Domain. HPSORT
is not free.
Non-registered users are granted a limited, 90-day license to
determine whether or not the program meets their needs. Con-
tinued use of HPSORT beyond the 90-day evaluation time period
requires registration of the program. Use of non-registered
copies of HPSORT beyond the original evaluation period is strict-
ly prohibited.
Copying and distributing HPSORT to others, is subject to the
above restrictions and the following:
o HPSORT must be copied in unmodified form, including the
file containing this license information.
o No copying fee of any type may be assessed other than
basic charges for the cost of the copying medium.
o Distribution of HPSORT with any other software or
hardware product(s) without the express written permis-
sion of CNT Software.
o Sysops (bulletin board SYStem Operators) may make
HPSORT available for downloading by their users as long
as all above conditions are met.
o Commercial Distributors of Public Domain, Shareware, or
User-Supported software may distribute HPSORT subject
to the above conditions only after getting written
permission from CNT Software and filling out a regis-
tration form for upgrade notifications.
2.3 Ordering Information
When you register your copy of HPSORT, you are granted a license
to use the program as you desire. There are several advantages
to registering your copy of HPSORT:
o Copy of the latest version of HPSORT
o Printed Manual
o E-Mail Support No problem is too big or small, but
you must be a registered user to get support.
o Notification of major releases with reduced upgrade
costs.
o You are contributing towards user supported software.
To register HPSORT, please send the completed registration form
at the end of this document.
5
3.0 Installation
3.1 System Requirements
o HPSORT requires an IBM PC,XT,AT,PS/2 or IBM
compatible computer with at least 384K RAM.
o Math coprocessor is highly recommended. A 12mhz 286
287 processor combination will preform equal to a 25mhz
386 processor without a coprocessor.
3.1 Installation
HPSORT is distributed with the following files -
o README.HST Read me first file
o HPSORT.EXE Sorting and Compression Program
o HP_CFG.EXE Configuration Program for HPSORT
o HPSORT.HLP Help file for HP_CFG.EXE
o HPSORT.DOC This document
Any missing files constitutes an incomplete copy.
Copy the files into either a separate directory or the current
CAD program's directory on your hard drive.
Run HP_CFG to create the configuration file (HPSORT.CFG) that
HPSORT requires for execution. The configuration file can either
be in the same directory as HPSORT or your current directory.
It is possible to have multiple configurations for different
applications. Do this by copying the "master" or "initial"
configuration file into the directory of the current application.
While in this directory, run HP_CFG to edit the parameters.
4.0 Configuration
HP_CFG is the configuration utility for HPSORT. This config-
uration program "tunes" HPSORT to your preferences. It stores
your choices in the file HPSORT.CFG. This configuration file
can be anywhere on your system as long as it is either in the
current directory or in a directory listed in the path.
All screens contain two status lines that appear on lines 23 and
25 of the display. Line 23 is a message that explains the menu
option or the data field that the cursor is at. Line 25 is the
current "sort & compress" or "compress only" mode (see section
4.4).
6
4.1 Control Keys
HP_CFG uses the following control keys:
Arrow Keys Moves the cursor between different menu or data items.
BACKSPACE Deletes the character to the left of the cursor and
moves the cursor one space to the left.
DELETE When editing data, deletes the character the cursor is
on.
ENTER When on a menu item, it executes the item. When on a
data field, stores that data in the field, then moves
the cursor to the next field.
ESC Exits the active data, help or menu screen.
F1 Displays a help message.
INSERT Toggles Insert Mode. In insert mode, characters are
inserted at the current cursor location. Any trailing
characters are pushed to the right and may be pushed
out of the field and lost.
PAGE UP Used on help screens to look at the previous page.
PAGE DOWN Used on help screens to look at the next page.
7
4.2 Opening Configuration Menu
Start this program by typing HP_CFG and pressing the ENTER key
from the DOS prompt.
After the HP_CFG opening screen, the following screen will
appear:
┌───────────────HPSORT Configuration Menu─────────────────┐
│Edit Default Sort Compress Save Quit │
└─────────────────────────────────────────────────────────┘
Select Data to Edit
Sort and Compress Output
This is the primary menu. Use the arrow keys, to select the
desired option, then press ENTER.
Warning: Pressing ESC key from this menu causes HP_CFG
to abort to MS-DOS. Changes are not saved.
EDIT This selects a menu that permits editing of the para-
meters. Refer to Page #8
DEFAULT For the listed CAD packages, HP_CFG can preconfigure
most parameters for you. This option selects the menu
that chooses which package.
SORT Configures HPSORT to sort and compress plot files.
This is the default mode.
COMPRESS Configures HPSORT to compress a plot file. The out-
putted file is not an exact representation of the input
file. HPSORT draws text using the built in plotter
fonts and lines separately.
8
SAVE Saves the configuration to file HPSORT.CFG in the
current directory.
QUIT Exits HP_CFG without performing a save.
4.2.1 Edit Configuration Data
After selecting EDIT on the opening menu, the following menu will
appear:
┌────────────HPSORT Configuration Menu────────┐
│Edit Default Sort Compress Save Quit │
┌───────────────┐─────────────────────────────┘
│General Data │
│Swap File │
│Labels │
│Serial Port │
│Disc Parameters│
└───────────────┘
Options are
General Data Controls the processing of lines. Adjust entries
here with care.
Swap File HPSORT can use a disc to expand its sorting capa-
city.
Labels Controls drawing of text using the built in plot-
ter fonts.
Serial Port Controls how HPSORT buffers and/or configures COM
ports.
Disc Parameters Controls miscellaneous disc and compression op-
tions.
9
4.2.2 General Data Editing
These parameters control how the HPSORT draws lines, arcs and
circles. They can directly affect plot quality, so adjust values
with care.
╔══════════════HPSORT Vector Parameter Setting══════════════╗
║ ║
║Near Zero Move Delta...... 0.010mm ║
║Pen Width Move Delta...... 0.030mm ║
║Short Near Zero Length..... 5.00mm ║
║Max. Numb Relative Moves. 5 ║
║Circle Check Radius....... 5.000mm ║
║Max. Relative Move....... 16000 ║
║ The following two lines are primarily for persons using ║
║ ORCAD. This has to do with how dashed lines are ║
║ implemented. Refer to the manual for proper settings. ║
║ ║
║Line Type Divider......... 3.500 ║
║Ignore IP Commands..Y/N... YES ║
║ ║
║ ║
╚═══════════════════════════════════════════════════════════╝
Parameters
Near Zero Move Delta
This parameter drops unnoticeable short moves. It controls
the pen motion from the end of one vector to the start of
the next. The parameter states:
When the end of the vector just drawn is closer
than this distance from the starting point of the
next vector, the pen will not move to the starting
point of the next vector.
10
As an example consider the following sequence:
a. Move with pen up to position #1.
b. Lower the pen and draw a line from point #1 to #2.
c. Raise the pen up and move to position #3.
d. Lower the pen and draw a line from point #3 to #4.
The two lines from #1 to #2
Example Plot of Two Lines
Close Together#1--------------------#2
#4---#3and from #3 to #4 would be
drawn as shown in figure to
the right.
This is how they will appear
when the distance from
Points #2 to #3 is larger
than this parameter.
When the distance between points #2 and #3 is less than or
equal to this parameter, then above example would generate
the following sequence:
a. Move with pen up to position #1.
b. Lower the pen and draw a line from point #1 to #(2&3).
d. Lower the pen and draw a line from point #(2&3) to #4.
Note in figure to right
#1-------------------+#(2&3)
/
/
#4that a single point
replaces points #2 and
#3. This effect
noticed on parallel
lines drawn close
together, but still
separate.
Typical value is 1/10 smallest pen size used. For 0.35mm
pen would be 0.035mm. Range is 0 to 1.5mm.
Pen Width Move Delta
This parameter removes pen up/down motions that are so short
that they are unnoticeable. Plotting speed is increased
because the pen is not lifted as much. HPSORT does this by
drawing a line between the two points that should not be
there. When this parameter is set correctly, the line is
unnoticeable. This parameter says:
When the end of the vector just drawn is closer
than this distance from the starting point of the
next vector, a line connects the points without
the pen lifting from the paper.
11
As an example consider the following sequence:
a. Move with pen up to position #1.
b. Lower the pen and draw a line from point #1 to #2.
c. Raise the pen up and move to position #3.
d. Lower the pen and draw a line from point #3 to #4.
The two lines from #1 to #2
Example Plot of Two Lines
Close Together#1--------------------#2
#4---#3and from #3 to #4 would be
drawn as shown in figure to
the right.
This is how they will appear
when the distance from
Points #2 to #3 is larger
than this parameter.
When the distance between
points #2 and #3 is less than or equal to this parameter,
then above example would generate the following sequence:
a. Move with pen up to position #1.
b. Lower the pen and draw a line from point #1 to #2.
c. Lower the pen and draw a line from point #2 to #3.
d. Lower the pen and draw a line from point #3 to #4.
The figure to right is how
#1-------------------+#2
|
|
|
#4---+#3the above example would be
drawn. Note the line
appearing between points #2
and #3 that was not in the
original sequence.
Typical values are 1/2 to
1/4 smallest pen size used.
Range is 0 to 1.5mm.
Short Near Vector Length
Before sending a vector to the output device, HPSORT checks
to see if a "short" vector touches it. If yes, then HPSORT
draws the "short" vector first. Range is 0 to 99.99mm, with
5 to 10mm being a good value. If this value is too large,
it is counter productive towards sorting.
12
Consider the lines in the
#1
\
\
\
#2 +--------------------#3figure to the right.
During the sorting
process, HPSORT decides
the next line to draw is
from points #2 to #3.
This parameter instructs
HPSORT to check to see if
a "short" line is connected to the line about to be drawn.
In this case, it is the line from points #1 to #2. If the
length of the line from points #1 to #2 is less than or
equal to the value of this parameter, then HPSORT will
output the following sequence:
a. Move with the pen up to position #1.
b. Lower the pen and draw a line from point #1 to #2.
c. Lower the pen and draw a line from point #2 to #3.
Maximum Number of Relative Moves
HPSORT uses primarily "relative" positioning. This is one
of the major techniques used to reduce file size. In this
mode, each pen move is the delta x, delta y from the end of
the last pen move. When positioning in relative mode, this
parameter controls how often an absolute positioning command
is issued to correct for any positioning errors in the
plotter.
What is "absolute" and "relative" positioning?
Absolute positioning is where each command tells the plotter
exactly where to position the pen on the paper independent
of any other move. Therefore, the pen is always in the
position where the CAD program expects it to be. An example
would be -
Move Pen Up to 1000,1000
Place Pen Down
Move to 1400,1000
Move to 1400,1400
Move to 1000,1400
Move to 1000,1000
The numbers are in plotter units and draw a square 1 cm on a
side.
13
Using the same example as above, HPSORT would output
Move Pen Up to 1000,1000 in absolute mode
Place Pen Down
Shift to relative mode
Move right 400 units
Move up 400 units
Move left 400 units
Move down 400 units
Notice that in the relative example, there is only one
command to tell the plotter exactly where to move. The rest
of the commands are move left, right, up or down commands.
They assume that the plotter pen is where it is suppose to
be. Due to cumulative errors in both calculations and
mechanical positioning in the plotter, every once in a
while, a absolute positioning command must be done.
The larger this parameter, the more the file size is
reduced. But the larger the chance of plotting errors.
Legal values range from 2 to 999. Values of 5 to 20 are
effective.
Check Circle Radius
Circles are a special case when compared to all of the other
types of line drawing commands. When at a start or end of a
line, HPSORT checks to see if a circle is either touching or
centered on the current position. If yes, then send the
circle to the output device.
This parameter controls how close the circle be in order to
be checked. If it is too small, HPSORT misses the circle
during the normal processing and is outputted during the
cleanup phase. If it is too large, then it will slow down
normal vector processing by needlessly checking too many
circles. A good value is dependant upon the average circle
size. Range of legal values is 0.01 to 99.99mm. Values of
5 to 10mm are effective.
If HPSORT draws too many circles during the cleanup phase of
the processing, try increasing this value.
14
Max. Relative Move
This defines the maximum move size in relative mode in
plotter units. Some plotters ignore large relative moves,
such as the HP 7450 DraftPro. For moves larger than this
parameter, HPSORT uses absolute moves instead of relative
moves. For most plotters, 16,000 is a good value.
Line Type Divider
When not using ORCAD, set value to 1.00.
The method ORCAD uses to draw dashed lines is not compatible
with the internal structure HPSORT uses to represent draw-
ings internally. See "Ignore IP Command" (next parameter)
for details. This parameter is a compromise that scales the
"dash" in the dashed line to fit the paper. Values are
dependant upon the normal drawing size:
Paper Size Value
---------- -----
A to B 1.5
B to C 2.5
C to D 3.5
D to E 4.5
B to D 3.0
Ignore IP Command
When not using ORCAD, set value to NO.
The IP is the "Input P1 and P2" command. This permits the
computer to redefine the meaning of P1 and P2 (refer to the
plotter manual for definition of P1 and P2).
The method ORCAD uses to output dashed lines is different
other packages. The HP plotter language defines dashed
lines is as a percentage of the distance from the opposite
corners of the paper. ORCAD, "redefines" the corners of the
paper, using the "IP" command to an "A" size drawing, draws
the dashed line and then redefines the paper size back to
normal.
Normally, when HPSORT finds an IP command, it outputs the
contents of the label and vector buffers, then outputs the
IP command. ORCAD uses this command for dashed lines. This
stops the pen motion optimization process whenever dashed
lines are encounter. When using ORCAD, set value to YES.
15
4.2.3 Swapping Polylines to Disc
This option controls how HPSORT handles a series of connected
lines (polylines)1 When these polylines are found, the only
where the starting and ending points are needs to be stored. The
rest of the information can be stored elsewhere while the program
is running. If this information is swapped to the disc, HPSORT's
effective capacity is increased.
If more than 4,000 vectors on a machine with 450k or more of free
RAM memory are normally processed in a single pass by HPSORT,
then these parameters will aid in performance.
When this option is selected, the following edit screen will
appear -
╔═════════════════Vector Buffering to Disc══════════════════╗
║ ║
║Swap Polylines to Disc................Y/N. YES ║
║ ║
║Collapse Rectangles to Single Command.Y/N. NO ║
║ ║
║ ----------- Swapping Options -------------- ║
║Drive to swap to................. C ║
║Swapping Threshold............... 005 ║
║Print Swapping Statistics....Y/N. NO ║
║ ║
║ ║
║ ║
╚═══════════════════════════════════════════════════════════╝
Swap Polylines to Disc
This parameter enables the rest of the options on this
screen. If YES, the swapping is enabled.
Electrical schematics usually do not benefit significantly
from this option. Mechanical drawings, particular drawings
by AUTOCAD, and PCB Layouts benefit significantly by setting
this parameter to YES.
1 In HPSORT, a polygon can be either close line a rec-
tangle or open like the line segments in the letter M.
16
Collapse Rectangles to Single Command
Set to NO. Current version does not support this option.
Drive to Swap To
Letter of the drive to use for buffering to disc. HPSORT
uses the current drive and directory if this field is blank.
If more than one hard drive is available, use the fastest
one available.
If a RAAM drive is present, size of 400kb is usually enough.
If running from a network, using the local hard drive will
give better performance rather that a drive on the file
server.
Swapping Threshold
This sets the minimum number of connected line segments
before swapping them to the disc. Swapping all connected
segments does not significantly give a better sort, but can
have a significant increase in plotting time. A good value
is one that is slightly less than the average number of
connected segments. For a starting value, 5 works well.
Range of values is 1 to 999.
Print Swapping Statistics
This parameter turns on the printing of the swapping statis-
tics. These statistics are useful in adjusting the other
parameters towards optimal values.
4.2.4 Label commands
These parameters control how HPSORT handles text plotted with the
built in plotter fonts2. The HPGL documentation refer to this
as a label command. One of the first questions that you should
ask is "Does my CAD program use built in fonts?". HP_CFG knows
the correct settings for those CAD programs listed in the Default
option (see section 4.3) on the opening menu.
If your program was not listed in the default settings, HPSORT
can make the determination. Set the "Label Commands Processed"
parameter to NO. If HPSORT finds a label command, HPSORT will
exit with a configuration error. Set the parameter to YES then.
2 What is a font. Font is the term used to describe the
shape of the letters as they are drawn.
17
Then set the "Print Labels Stats" command to yes to determine the
correct buffer sizes.
╔══════════════════HPSORT Label Parameters══════════════════╗
║ ║
║Label Commands Processed.....Y/N..... YES ║
║Ignore Single Space Labels...Y/N..... YES ║
║Print Labels Stats...........Y/N..... NO ║
║Map Font 0 to Font 99........Y/N..... YES ║
║ ║
║ --- Relative Label Positioning Commands --- ║
║Position Labels in Relative Mode..Y/N. YES ║
║Max Number Relative Moves............. 20 ║
║ ║
║ ------- Label Buffer Sizes -------- ║
║Max Number Labels in Memory at one time..... 1000 ║
║Max kb to store labels...................... 48 ║
║ ║
║ ║
╚═══════════════════════════════════════════════════════════╝
Label Commands Processed
This flag controls how HPSORT supports the Label command.
There are two methods of printing text on a drawing. Pro-
grams such as AUTOCAD, output all text as a series of line
segments. This permits the program to support a variety of
fonts. Some programs such as ORCAD or SCHEMA, use only
those fonts built into the plotter. Some programs such as
Point Line CADD, use both methods.
Setting this parameter to NO effectively increases the
amount of memory available for sorting lines.
Ignore Single Space Labels
If the CADD program is try to plot a single space character
using the built in plotter fonts, ignore the command. This
parameter normally should be to YES.
Print Label Stats
This parameter turns on the printing of the labels statis-
tics. These statistics are useful in adjusting the other
parameters towards optimal values.
18
Map Font 0 to Font 99
This parameter when YES will change the appearance of some
or all the text on your drawing for those CAD programs that
use the built in plotter fonts. Normally font 0 is used.
While this font is okay, the 5, 6 & S and 8 & B characters
are difficult to tell apart. HPSORT can substitute plotter
font 99 which is designed to make telling these characters
apart easier.
Position Labels in Rel Mode
This parameter controls positioning of labels using relative
instead of absolute positioning. For a discussion on the
difference between the positioning mode, refer to "Maximum
Number of Relative Moves" on page #? for more details. This
results in smaller output files.
Max Number Relative Moves
When positioning labels in relative mode, this controls how
often an absolute positioning command is issued to correct
for any positioning errors in the plotter.
The net effect of this parameter is that the larger the
value, the more the file size compression, but the larger
the chance of plotting errors. Legal values range from 2 to
999. Values of 5 to 20 are effective.
Max Number Labels in Memory at one time
This is the maximum number of labels to reserve space for
before outputing the buffer. Use label statistics to deter-
mine a good value. If the maximum value printed on the
stat's is "close" to the current value, try increasing this
value by 10%. Range of values are 30 to 2,0000.
Max kb to store labels
Number of kilobytes of memory to reserve for the to store
the actual text of the labels. Range of values is 3 to 64.
Use label statistics to determine a good value. If the
maximum value printed on the stat's is "close" to the cur-
rent value, try increasing this value by 10%.
19
4.2.5 Serial Input / Output Communication Parameters
HPSORT has full control over serial ports. HPSORT can set all of
the serial port parameters without the use of the DOS MODE
command.
HPSORT has a simple built in spooler to the serial port. This
permits HPSORT to output to a plotter while performing it's
calculations.
When you select this option, the following edit screen will be
displayed:
╔═══════════════HPSORT Serial Port Parameters═══════════════╗
║ ║
║Buffer Serial Output..............Y/N. NO ║
║Buffered Serial Output Buffer Size.... 32kb ║
║ ║
║---------- Serial Communication Parameters ------------ ║
║Have HPSORT set serial parameters.Y/N.. NO ║
║Word size.............................. 8 ║
║Baud Rate.............................. 9600 ║
║Parity 0-NONE 1-EVEN, 2-ODD........... NONE ║
║Number Stop Bits (1 or 2).............. 1 ║
║ ║
║ ║
╚═══════════════════════════════════════════════════════════╝
Buffered Serial Output
HPSORT contains a simple serial port spooling program when
the output device is either COM1, COM2, COM3 or COM4. This
exists so if you do not already have a spooling program on
your system, HPSORT can send data to the plotter while it is
processing.
There are two restrictions on this function:
1 - The plotter must use the hardware same style of
handshaking as used by MS-DOS. If you can copy your
file to the plotter using the MS-DOS "COPY" command,
there will be no problems with the built in spooler.
2 - HPSORT will not exit until the plotter has received all
of the data.
20
Buffered Serial Output Buffer Size
When enabling the serial port buffering, this is the number
of kilobytes of memory to reserve. Value can be from 3kb
to 32kb.
Have HPSORT set serial parameters
This parameter has meaning only when the output file is
either COM1, COM2, COM3 or COM4. When this parameter is
NO, HPSORT does not change the parameters from when it
begins. If YES, then the parameters are set to the
parameters in this section.
Word Size
Number of bits in each data byte sent. Must be the same as
the plotter. Normally, will be 8, but can be 7.
Baud Rate
Baud Rate to set serial port to. Must be the same value as
the plotter. Legal values are only those values displayed.
Parity 0-NONE 1-EVEN, 2-ODD
Can be only one of the three values listed in the options
menu. Must be the same value as the plotter.
Number Stop Bits (1 or 2)
Legal values are 1 or 2. Must be the same value as the
plotter. Normally, will be 1 unless sending at 110 baud.
4.2.6 Disc Parameters
HPSORT has two groups of parameters that control the output file
name. The first group has to do with the default output file
name. These are the first two parameters.
The second is to automatically invoke the file compression
program of your choice. For those users that communicate with a
plotting service bureau, HPSORT can automatically invoke your
compression program.
When you select this option, the following edit screen will be
displayed:
21
╔═════════════════HPSORT Disc I/O Parameters════════════════╗
║Default Output File Name..................HPSORT.OUT ║
║Rename Output file to Input file name.Y/N.YES ║
║ ║
║If you use data compression programs to shrink the size of ║
║the plot files before they are sent to a plotting service ║
║bureau, HPSORT can automatically invoke your favorite ║
║compression program. Please refer to the manual for full ║
║details as to how to use this option. ║
║ ║
║ ║
║Add Output File to Compressed file........Y/N.. NO ║
║Compression File Name (must be pathed in)...... ║
║Compression File Program parameters............ ║
║Compression File to add output to.............. ║
║ ║
╚═══════════════════════════════════════════════════════════╝
Default Output File Name
Default name of file to send output. When HPSORT runs, this
is the file name used if no output file is present. The
default value is HPSORT.OUT.
This field can contain a device name. For example if the
value is COM1:, all output would by default goes to serial
port #1.
NOTE: If the parameter to "Rename Output to Input" is
YES, then this parameter has no meaning.
Rename Output file to Input file name
If set to YES, HPSORT sends it's output to a temporary
file. When HPSORT completes, the input file is renamed with
a ".BAK" extension and the temporary output file will be
renamed to the input file name.
22
Add Output File to Compressed file
If you routinely use service bureaus to plot your drawings,
these can be compressed by a programs such as ARC, PKXARC,
LHARC, etc. By setting this parameter to YES, HPSORT will
automatically send the output file to the compression pro-
gram. The rest of the parameters, define how to pre-form
this operation.
WARNINGS: The output file name must be unique. If
not, then the compressed file will con-
tain only the last file processed.
Compression File Name (must be pathed in)
Name of you compression program to use. Examples would be
PKZIP, ARC or LHARC. The program must be either in the
current directory or path.
Compression File Program parameters
List of any commands required by the compression program to
process the file.
Compression File to add output to
Name of compressed file to store data in. This cannot be
selected from the command line.
4.3 Default Settings
HP_CFG can automatically configure HPSORT for the listed software
on the menu. If the software that you use is not listed, then
choose "Default CAD". The settings should work for most
packages.
The "Default Serial Parameters" option configures the serial port
for 9600 baud, no parity, 8 data bits and 1 stop bit.
23
┌───────────────────────HPSORT Configuration Menu─────────────────────┐
│Edit Default Sort Compress Save Quit │
└──────┌─────────────────────────┐────────────────────────────────────┘
│AutoCad │
│ORCAD │
│Point Line CADD │
│Schema │
├─────────────────────────┤
│Default CAD │
│Default Serial Parameters│
└─────────────────────────┘
4.4 Sort / Compress
The primary purpose of HPSORT is the pen motion optimizing. If
your CAD package does do pen motion optimizing and wish only to
compress the plot file, then select the "Compress" option on the
menu.
In Compress mode, the plot file is not sorted. It is split into
lines and label commands. Then each of these two sections are
separately outputed in the order that the commands were read in.
4.5 Save
Stores parameters to file "HPSORT.CFG" in the current directory.
4.6 Quit
Exits configuration utility without save any parameters. Use the
"Save" command to save the parameters.
5.0 Operation
To execute HPSORT, type the following command line:
HPSORT "INPUT FILE NAME" "OUTPUT FILE NAME"
INPUT FILE NAME This is the name of the file to be processed.
OUTPUT FILE NAME This is an optional parameter that specifies
the where the sorted file is to be placed.
Note if this value is not specified, then the
parameters in section 4.8 control output file
name.
24
HPSORT displays the following status messages when running -
"Vector Buffer Full - XX% How much memory is used while
reading in the source file.
"Number of Vectors - x,xxx" This is the number of vectors that
HPSORT is processing.
"Vector Buffer Left - XX%" Percentage of buffers left to sort
and output. Percent is comparing
the number of vectors (lines) left
with the number of vectors when
this phase started..
"Label Buffer Left - XX%" Percentage of the label buffer left
to sort and output. Percent is
comparing number of labels left
with the number of labels when this
phase was started.
"Waiting for Output Queue to Empty" This message appears only
when Serial Port Output Buffer
(Section 4.2.5) has been enabled
and the output file was a COM port.
The next line contains the number
of bytes left in the buffer to
output.
5.1 Theory of Operation
The technical description of how HPSORT works is that it preforms
a topological sort. What this means is that it tries to minimize
the overall pen motion. HPSORT does not attempt to do the best
possible sort. What it does do is do, is a good sort quickly.
HPSORT works under a self imposed time restriction. The bench-
mark time is a system where the plotter is directly connected to
20mhz 386/387 computer system with 500kb free RAM. HPSORT has
perform the sort and send the results to the plotter in same
amount of time than it takes MS-DOS COPY command to perform the
same operation.
Doing the sort that it does do, plots will generally plot in 10%
to 30% (had one case of 54%) less time. It was our judgement,
that the processing time to get the best possible sort was not
worth the plotting time saved. Future versions of HPSORT will
have improved routines both for processing speed and plotting
speed.
25
In operation HPSORT has three separate phases:
1 Read in the input plot file and decode it.
2 Sort and output the lines, circles and arcs.
3 Sort and output any text that uses the built in
plotter fonts.
These three phases generally run in the order displayed.
Commands that flush the internal buffers (e.g., a pen change) or
if the label or vector buffer fills up disrupt this order.
5.2 HPSORT & Desqview
When running HPSORT with Desqview, having a partition size of at
least 320kb is required. The more ram available to HPSORT the
faster it will run.
The only problem noticed is when HPSORT is running at the same
time as your CAD package is. As HPSORT is a compute intensive
program, your CAD package will appear to slow down while HPSORT
is running.
6.0 problems
Refer to the README file for a the list of known problems with
this version.
6.1 Error Messages
HPSORT has three types of error messages. In the first tow
cases, the message includes text as to how to fix or work around
the problem.
CONFIGURATION -These messages occur when the HPSORT.CFG file and
the input file contain values that are in conflict
with each other.
RUNTIME - These messages occur when HPSORT cannot do some
operation.
INTERNAL - These messages occur when HPSORT detects an
internal error. If you get one of these messages,
please contact the author (section 6.2).
26
6.2 Incompatibilities
If HPSORT is not buffering serial output, there are no known
incompatibilities.
HPSORT may not operate properly when other background software is
running and it is buffering serial output. By other background
software, we mean programs that are loaded in the CONFIG.SYS,or
by a BAT file and remain in memory. Certain screen clock pro-
grams, for example, are known to interfere with serial port
operations.
Conflicts with HPSORT may not be caused by a single program, but
by a combination of programs, which, taken singly, cause no
problems. Therefore, if you suspect some conflict, you should
boot your system with only absolutely necessary device drivers
and resident programs (i.e. a partitioned disk device driver).
Then add programs back in one at a time.
6.3 How to contact CNT Software
We have support for messages and technical support on JADE BBS at
(608) 752-7840 When calling, set your modem up for 8 data bits,
no parity and 1 stop bit. Leave a private message for "Tom
Thorp".
If you need to send us your plot file for analysis, please send
to:
CNT Software
1615 Highland Ave.
Janesville, Wis. 53545
We use both 5 1/4 & 3 1/2 inch diskettes. Please include the
following information:
o Version of HPSORT
o CAD or Graphics Program
o Make and model of Plotter
o Version of DOS
27
Order Form
INVOICE # 91-0331
Remit To:
CNT Software
1615 Highland Ave
Janesville, Wisw3545
Qty. Description Amount
____ HPSORT Registration $50.00 ea __________
____ HPSORT Printed Manual $19.95 ea __________
Shipping (see below) __________
(Wis. residents add 5% sales tax) Tax __________
Total __________
Purchase Orders less than $100 must be pre-paid.
Name: _____________________________________________________
Company _____________________________________________________
Address: _____________________________________________________
_____________________________________________________
_____________________________________________________
Work Phone: (____) ________________
Home Phone: (____) ________________
Comments: ____________________________________________________
____________________________________________________
____________________________________________________
____________________________________________________
Note: Shipping to 48 continental states is $5.00. Alaska, Hawaii, and Canada
is $10.00. Other countries, please call before ordering.
28
Site License Information
If you plan on using HPSORT in a corporation, government office, or for any
business purpose whatsoever, registration is mandatory and the 90 day limited
license is strictly enforced. Quantity discounts are available under a Site
License agreement:
One MASTER copy of HPSORT disc per site is supplied and one copy
of the manual is supplied per user.
For all site licenses, the customer must appoint a single contact
person with whom all HPSORT related dealings will take place.
Should a problem occur, that person, must report the problem and
arrange for its resolution. All HPSORT program updates will be
forwarded to the contact person. When filling out the order form,
please use the contact person's name to prevent any later
misunderstandings.
Site license discount rates are:
Total Copies Discount per Unit
2 to 10 20%
11 to 50 40%
51+ 50%
NOTE: All prices and discounts are subject to change without notice.
Discounts are not cumulative. They apply to separate orders only.
29